<template>
	<view class="mt60 pd">
		<input type="text" value="" placeholder="请设置群组名称" class="jhhgerttyt" v-model="form.name"/>
	</view>
</template>
<script>
	export default {
		data() {
			return {
				form:{
					name:'',
					ids:''
				}
			}
		},
		onNavigationBarButtonTap() {
			this.dengljse() 
			// uni.redirectTo({
			// 	url: '/pages/user/TransportManagement/MyGroup'
			// })
		},
		components: {},
		methods: {
			async dengljse() {
				let cs = {}
				cs.name = this.form.name
				cs.ids = this.form.ids
				if (!cs.name) {
					uni.showToast({
						title: '请输入群组名称'
					});
					return false;
				}
				let jhsd = await this.post("/api/group", cs)
				
				console.log(jhsd)
				// uni.redirectTo({
				// 	url: 'index'
				// })
				// return 
				uni.redirectTo({
					url: '/pages/user/TransportManagement/MyGroup'
				})
			}
		},
		onLoad(options){
			// this.form.ids = options.data
			this.form.ids = '26,28,27'
			console.log(options)
		},
		mounted() {}
	}
</script>
<style scoped>

</style>
